import request from '@/utils/request'
/**
* get list ?
* @param params {*}
*/
export function _get (params) {
    return request({
        url: '/supplier/getPurchaseOrderByPage',
        method: 'get',
        params: params
    })
}

export function _getAllPurchaseOrder (params) {
    return request({
        url: '/supplier/getAllPurchaseOrder',
        method: 'get',
        params: params
    })
}

export function _getPurchaseOrderGoodsById (idPurOrd) {
  return request({
    url: '/supplier/getPurchaseOrderGoodsById?idPurOrd=' + idPurOrd,
    method: 'get'
  })
}
/**
* get row ?
* @param params {*}
*/
export function _find (params) {
    return request({
        url: '/supplier/findPurchaseOrderByPage',
        method: 'get',
        params: params
    })
}

// 新增數據
export function _post (params) {
    return request({
        url: '/supplier/addPurchaseOrder',
        method: 'post',
        data: params
    })
}
// 修改數據
export function _put (id, params) {
    return request({
        url: '/supplier/editPurchaseOrder?idPurOrd=' + id,
        method: 'put',
        data: params
    })
}
// 刪除數據
export function _delete (params) {
    return request({
        url: '/supplier/deletePurchaseOrder',
        method: 'delete',
        params: params
    })
}
